package net.csdn.business.common.domain.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import net.csdn.business.common.constant.CommonConstants;

import java.util.Date;

/**
 * @author wanghang
 * @version 1.0
 * @date 2022/11/7 16:24
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
@JsonInclude(JsonInclude.Include.NON_NULL)
public class MilepostVo {

    /**
     * 里程碑ID
     */
    private String objectId;

    /**
     * 里程碑名称
     */
    private String goalName;

    /**
     * 里程碑描述
     */
    private String goalDesc;

    /**
     * 状态 1-已开启 2-已关闭
     */
    private Integer goalStatus;

    /**
     * 所属组织或仓库的ID
     */
    private String sourceId;

    /**
     * 所属组织或仓库的类型：1:组织；2:仓库
     */
    private Integer sourceType;

   /* @JsonSerialize(using = ToStringSerializer.class)
    private Long projectId;*/

    /**
     * 截止日期
     */
    @JsonFormat(pattern = CommonConstants.DEFAULT_PATTERN, timezone = CommonConstants.DEFAULT_TIMEZONE)
    private Date deadline;

    protected String createdBy;
    protected String lastModifiedBy;
    @JsonFormat(pattern = CommonConstants.DEFAULT_PATTERN, timezone = CommonConstants.DEFAULT_TIMEZONE)
    protected Date createdDate;
    @JsonFormat(pattern = CommonConstants.DEFAULT_PATTERN, timezone = CommonConstants.DEFAULT_TIMEZONE)
    protected Date lastModifiedDate;

    /**
     * 统计
     */
    private MilepostIssueSumVo stat;

}
